package com.tmt.im.service.controller.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.tags.Tag;
import jakarta.annotation.Nullable;
import jakarta.validation.constraints.Min;
import jakarta.validation.constraints.NotEmpty;
import jakarta.validation.constraints.NotNull;
import lombok.Getter;
import lombok.Setter;

import java.io.Serial;
import java.io.Serializable;
import java.util.List;

import static io.swagger.v3.oas.annotations.media.Schema.RequiredMode.NOT_REQUIRED;
import static io.swagger.v3.oas.annotations.media.Schema.RequiredMode.REQUIRED;

/**
 * @Description TODO
 * @Author wuyi
 * @Date 2024/8/30 15:22
 * @Version 1.0
 **/
@Getter
@Setter
@Tag(name = "JoinSessionRequest", description = "拉人入群请求对象")
public class JoinSessionRequest implements Serializable {

    @Serial
    private static final long serialVersionUID = 1699989018314875896L;

    @Schema(requiredMode = REQUIRED, description = "要加入的群组ID")
    @NotNull(message = "群组ID不能为null")
    @Min(value = 1, message = "群组ID不能小于1")
    private Long tid;

    @Schema(requiredMode = REQUIRED, description = "被邀请的成员ID列表")
    @NotNull(message = "被邀请的成员ID列表不允许为null")
    @NotEmpty(message = "被邀请的成员ID列表不允许为空列表")
    private List<Long> memberIds;

    @Schema(requiredMode = NOT_REQUIRED, description = "邀请信息")
    @Nullable
    private String inviteMsg;

}
